import Vue from 'vue'
import App from './App.vue'
import router from './router/router.js'
import less from 'less'
import ElementUI from 'element-ui'
import toast from '@/components/Toast.js'

import 'element-ui/lib/theme-chalk/index.css'
import './assets/style/theme/index.css'
import './assets/fonts/iconfont.css'
import store from '../src/store/index.js'

import CkElementUI from '@/components/index.js'
import confirm from '@/components/Confirm.js'
import baseInfo from './utils/config'
import util from './utils/util'
import { numberToCurrencyNo } from '@/utils/numberToCurrency'
import { moneyDelete } from '@/utils/numberToCurrency'

import './assets/style/tailwind.css'

import {
  formatDate,
  getQuarter,
  pickerOptions
} from '@/utils/publicFun'
import './assets/style/global.css'
// 引入自定义指令
import waves from '@/directive/waves'
Vue.directive('waves', waves)

import moment from 'moment'
Vue.prototype.$moment = moment

Vue.config.productionTip = false
Vue.prototype.$util = util
Vue.use(less)
Vue.use(ElementUI)
Vue.use(CkElementUI)
Vue.prototype.$toast = toast
Vue.prototype.$confirm = confirm
Vue.prototype.$baseInfo = baseInfo
Vue.prototype.$moneyDelete = moneyDelete
Vue.prototype.$numberToCurrencyNo = numberToCurrencyNo
Vue.prototype.$formatDate = formatDate
Vue.prototype.$getQuarter = getQuarter
Vue.prototype.$pickerOptions = pickerOptions
Vue.filter('numberToCurrency', numberToCurrencyNo)

new Vue({
  router,
  store,
  render: h => h(App)
}).$mount('#app')
